import {ModalFormTreeOption} from '@/type/ModalFormType'
import {categoryListType} from '@/view/shopping/category/category'

export interface BrandSaveType {
  brand_name: string
  category_id: string
}

export interface BrandSaveFormType {
  brand_name: string
  category_id: string[] | string
}

export interface BrandIdType {
  brand_id: string
}

export interface BrandUpdateType extends BrandSaveType, BrandIdType {}

export interface BrandListResType extends BrandUpdateType{
  category_name: string
}

export interface BrandListFormType {
  brand_name: string
  category_name: string
}


export const brandColumns = (h) => [
  {
    title: "品牌名称",
    align: 'center',
    key: "brand_name"
  },
  {
    title: "分类名称",
    align: 'center',
    key: "category_name"
  },
  {
    title: "操作",
    align: 'center',
    key: "category_id",
    width: "140",
    render: (r: BrandListResType) => h(r)
  },
]


export function BrandTree (node: categoryListType):ModalFormTreeOption {

}
